package com.hujiang.basic.search.handler.impl;

import com.hujiang.basic.framework.plugin.mq.consume.AckableHandler;
import com.hujiang.basic.search.api.IndexService;
import com.hujiang.basic.search.model.HJUpdateByQueryRequest;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class UpdateByQueryHandler implements AckableHandler<HJUpdateByQueryRequest> {

    @Autowired
    private IndexService service;

    @Override
    public Object handle(HJUpdateByQueryRequest req) {
        return service.updateByQuery(req);
    }
}
